home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Animation How-To
/
Animation How-to CD.iso
/
PLY
/
CHAPTER4
/
IMPACT
/
SPLASH.BAS
< prev
Wrap
BASIC Source File
|
1994-01-01
|
1KB
|
52 lines
' SPLASH.BAS
SCREEN 12
WINDOW (-1, -1.5)-(141, 2)
LINE (0, -1)-(140, 5), , B
pi = 3.14159
rad = pi / 180
FOR y = 0 TO 5
LINE (0, y)-(140, y)
NEXT y
FOR x = 0 TO 140 STEP 20
LINE (x, -1)-(x, 5)
NEXT x
FOR frame = 0 TO 140
'VVVVVVVVVVVVVVVVVVVVVVVV
' The spreading wavefront
'AAAAAAAAAAAAAAAAAAAAAAAA
IF (frame < 40) THEN
center = COS((frame) * 4.8 * rad) + 1
ELSE
center = (frame - 40) / 20
END IF
' VVVVVVVVVVVVVVVVVVVVVVVVVVV
' The height of the wavefront
' AAAAAAAAAAAAAAAAAAAAAAAAAAA
IF (frame < 20) THEN
decline = 0
ELSE
IF (frame < 50) THEN
'expando goes from 0 to 1 between frames 20 and 50
'this makes the gain on the sine wave go from -.65 to -1.3
expando = ((frame - 20) / 30)
decline = -(.75 + expando*.65) * SIN(9 * (frame - 20) * rad)
ELSE
decline = 5 / EXP(frame / 40)
END IF
END IF
CIRCLE (frame, center), .2, 2
CIRCLE (frame, decline), .2, 3
NEXT frame